<template>
  <div class="left-container">
    <h3>Left 组件</h3>
    <hr />

    <p>count 值: {{ count }}</p>
    <button class="btn btn-primary" @click="add">+1</button>
    <button class="btn btn-primary" @click="jiaWind(10)">等一等加</button>
  </div>
</template>

<script>
import { mapState, mapActions } from 'vuex'
export default {
  name: 'Left',
  data() {
    return {}
  },
  computed: {
    ...mapState('Day6VuexOptions', ['count'])
  },
  methods: {
    add() {
      this.$store.commit('Day6VuexOptions/MusicAdd')
    },
    ...mapActions('Day6VuexOptions', ['jiaWind'])
  }
}
</script>

<style></style>
